<?php
namespace application\admin\panels;
class system_settings extends panel {
	public $name = 'System Settings';
	public function title() {
		return 'System Settings';
	}
	
	public function handleData() {
		if($_REQUEST['update_settings']) {
			setOption('browsing_method', $_REQUEST['browsing_method']);
			

			$this->addMessage('success', 'Settings successfully updated.');
		}
	}
	public function display() {
	?>
		<div class="box">
			<h3>System Settings</h3>
			<div class="box-content">
				<form method="post">
					<h4>Browsing Method</h4>
					<ul class="form-fields">
						<li>
							<label><input type="radio" checked="checked" name="browsing_method" value="normal"/> Normal</label>
						</li>
						<li>
							<label><input type="radio"  <?=(getOption('browsing_method') == 'ajax') ? 'checked="checked"' : ''?> name="browsing_method" value="ajax"/> AJAX</label>
						</li>
					</ul>
				</form>
			</div>
		</div>
		
			
		<?php	
	}
}
?>